﻿CREATE TABLE [ohrs].[HospitalPolyclinic] (
    [Id]           INT IDENTITY (1, 1) NOT NULL,
    [HospitalId]   INT NOT NULL,
    [PolyclinicId] INT NOT NULL,
    [State]        BIT CONSTRAINT [DF_HospitalPolyclinic_State] DEFAULT ((1)) NOT NULL,
    CONSTRAINT [PK_HospitalPolyclinic] PRIMARY KEY CLUSTERED ([Id] ASC),
    CONSTRAINT [FK_HospitalPolyclinic_Hospital] FOREIGN KEY ([HospitalId]) REFERENCES [ohrs].[Hospital] ([Id]),
    CONSTRAINT [FK_HospitalPolyclinic_Polyclinic] FOREIGN KEY ([PolyclinicId]) REFERENCES [ohrs].[Polyclinic] ([Id])
);



